<?php
    $sideItems =//el sideBar deepende del controllador
         array(
                /*array(  
                    'label' => 'Nuevo',
                    'link' => base_url().'paciente/nuevoPaciente',
                    'icon'=>'plus',
                    'active'=> ($this->uri->segment(2)=="nuevoPaciente")),*/
             array(  
                    'label'     => 'Buscar',
                    'link'      => base_url().'personal/buscar',
                    'icon'      => 'search',
                    'active'    => ($this->uri->segment(2)=="buscar")
                    ),   
             array(  
                    'label'     => 'Mis pacientes',
                    'link'      => base_url().'serviciosA/ambulatoria',
                    'icon'      => 'th-list',
                    'active'    => ($this->uri->segment(2)=="ambulatoria")
                    )
                
            );
    
?>

<div class="well sidebar-nav">
    <ul class="nav nav-list">
        <li class="nav-header">Personal</li>        
        <?php
            foreach ($sideItems as $sideItem){
                $activeStr = "";
                if ($sideItem['active']) $activeStr ="class='active'";
                echo "<li ".$activeStr.">
                        <a href='".$sideItem['link']."'>".
                            '<i class="icon-'.$sideItem['icon'].'"></i>'.$sideItem['label'].
                        "</a></li>";
            }
        ?>
    </ul>
</div>